package com.jp.knowledge.view;

import android.content.Context;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.widget.LinearLayout;

import com.jp.knowledge.util.L;

/**
 * Created by jiayen on 17/6/19.
 */

public class JpTouchLinearLayout  extends LinearLayout {
    public JpTouchLinearLayout(Context context) {
        super(context);
    }

    public JpTouchLinearLayout(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    public JpTouchLinearLayout(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    @Override
    public boolean onInterceptTouchEvent(MotionEvent ev) {
        switch (ev.getAction()){
            case MotionEvent.ACTION_UP:
                L.i("onInterceptTouchEvent","拖动完成");
                break;
            default:
                break;
        }
        return super.onInterceptTouchEvent(ev);
    }
}
